package com.atguigu.tms.mock.service.adv;


import com.baomidou.mybatisplus.extension.service.IService;

import java.util.List;
import java.util.Map;


public interface AdvService<T>  extends IService<T> {


    public Map<Long,T> all(boolean useCache);

//    public boolean saveOrUpdate(T entity );

//    public boolean saveOrUpdateBatch(List<T> list, int batchSize );

    public void truncateTable();

    public boolean saveOrUpdate(T entity, Boolean useCache);



    public boolean saveOrUpdateBatch(List<T> list, int batchSize, Boolean useCache);

    public T  getById(Long id, Boolean useCache);

    public T  getOneByRandom();

    public  void removeWithCache();

    public void loadCache();
}
